package com.acmen.demo.executor;

import com.acmen.easyapi.model.Response;
import com.alibaba.fastjson.JSON;
import com.acmen.demo.dto.cmd.UserAdd;
import com.acmen.demo.dto.cmd.UserUpd;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service;

/**
 * 用户 业务层处理
 *
 * @author acmen
 */
@Service
public class UserSaveExe {
    private static final Logger log = LoggerFactory.getLogger(UserSaveExe.class);
    /**
     * 新增用户
     */
    public Response create(UserAdd user) {
        log.info("创建用户,user={}", JSON.toJSONString(user));
        return Response.build(true);
    }

    /**
     * 修改用户
     */
    public Response update(UserUpd user) {
        log.info("修改用户,user={}", JSON.toJSONString(user));
        return Response.build(true);
    }

}
